// Entity
package com.lingnan.entity.po;

import lombok.Data;
import jakarta.validation.constraints.*;
import java.util.Date;

@Data
public class ChatSession {
    private Long id;

    @NotNull(message = "求职者ID不能为空")
    private Long seekerId;

    @NotNull(message = "HR ID不能为空")
    private Long hrId;

    private Long positionId;

    @Size(max = 255, message = "最后消息内容长度不能超过255个字符")
    private String lastMsg;

    private Date lastMsgTime;

    @Min(value = 0, message = "未读消息数不能为负数")
    private Integer seekerUnreadCount = 0; // 求职者未读数
    @Min(value = 0, message = "未读消息数不能为负数")
    private Integer hrUnreadCount = 0;    // HR未读数

}